package com.example.http;

import android.os.Handler;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.support.v7.app.WindowDecorActionBar;
import android.webkit.WebView;

public class MainActivity extends AppCompatActivity {

    private WebView webView;

    private Handler handler = new Handler();
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);

        webView = findViewById(R.id.webview);
        //创建httpthread对象
        new HttpThread("https://www.baidu.com", webView, handler).start();
    }
}
